﻿using System;
using System.Collections.Generic;
using System.Text;

namespace ConsoleApp2
{
    class yg
    {
        public string name;
        public string add;
        public yg(string name, string add) 
        {
            this.name = name;
            this.add = add;
        }
    }

    class cheng : yg 
    {
        int ticheng;
        public cheng(string name,int ticheng,string add):base(name,add)
        {
            this.ticheng = ticheng;
            Console.WriteLine("姓名：{0}\n 工资：{1}\n 地址：{2}",name,ticheng+2000,add
                ) ;
        }
    }


    class mi : yg
    {
        int gongzi;
        public mi(string name, string add) : base(name, add)
        {
            this.gongzi = gongzi;
            Console.WriteLine("姓名：{0}\n 工资:3000\n地址：{1}", name,add
                );
        }
    }

    class gaoguan: yg
    {
        int dixin;
        public gaoguan(string name,int dixin, string add) : base(name, add)
        {
            this.dixin = dixin;
            Console.WriteLine("姓名：{0}\n 工资:{1}\n地址：{2}", name,dixin+5000, add
                );
        }
    }

    class qingjie : yg
    {
        int gongzi;
        public qingjie(string name, string add) : base(name, add)
        {
            this.gongzi = gongzi;
            Console.WriteLine("姓名：{0}\n 工资:2000\n地址：{1}", name, add
                );
        }
    }
}
